Posted by Kelvin McDowell from a3a40755.sympatico.bconnected.net (209.53.4.93)on March 23, 1999 at 22:12:34:
In Reply to: Re: Grazy multitexture idea!!! posted by Jari Jokivuori on March 23, 1999 at 03:51:28:
One of the reasons lightmaps are used is to save memory. Have a whole bunch of low-res lightmaps and a single hi-res texture and blend at run-time instead of having a prohibative amount of hi-res pre-blended textures. So with your method you could say have a 256x256 texture. 128x128 of this is texture and that leaves 3 128x128 blocks left for lightmaps. Let's say your lightmaps are 32x32 so you get 16 lightmaps in a 128x128 block. All together you have a 256x256 texture which is actually a single 128x128 texture and 48 lightmaps.
Unfortunatly, many (most?) cards store textures in a 'twizzled' format (PowerVR2 and RivaTNT for instance) and bi-linear filtering is only free when they are in that format.
Instead of this:
00 01 02 03
04 05 06 07
08 09 10 11
12 13 14 15
They store this:
00 02 08 10
01 03 09 11
04 06 12 14
05 07 13 15
This way when four texels are fetched for use in producing a bilinearly filtered pixel there is a good chance that they will close to each other in memory. Hopping around memory is slower than getting several adjacent locations and doesn't cache well.
Kelvin.